﻿<%@ Page Language="C#" MasterPageFile="~/ControPanel.Master" AutoEventWireup="true"
    CodeBehind="ChangePassword.aspx.cs" Inherits="Continental.UI.ControlPanel.ChangePassword" %>

<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
    <div id="content">
        <div class="content_panel_left fl">
            <div class="box_container" style="width: 99%;">
                <div class="title_bar">
                    <div>
                        Trang cá nhân</div>
                </div>
                <ul style="padding-left: 10px;">
                    <li><a href="#">Danh sách tin đăng</a> </li>
                    <li><a href="#">Danh sách tin lưu chữ</a> </li>
                    <li><a href="/Thanh-Vien/doi-thong-tin-ca-nhan.aspx">Thay đổi thông tin cá nhân</a>
                    </li>
                    <li><a href="/Thanh-Vien/doi-mat-khau.aspx">Đổi mật khẩu</a> </li>
                    <li><a href="/Thanh-Vien/dang-xuat.aspx" onclick="return confirm('Bạn thực sự muốn hoát');">Thoát/Logout</a> </li>
                </ul>
            </div>
        </div>
        <div class="content_panel_right fr">
            <div class="box_container" style="width: 100%;">
                <div class="title_bar">
                    <div>
                        Thay đổi mật khẩu</div>
                </div>
                <table>
                    <tbody>
                        <tr>
                            <td colspan="2">
                                <span style="color: Red;">
                                    <%= message%>
                                </span>
                            </td>
                        </tr>
                        <tr>
                            <td>
                                <span>Mật khẩu hiện tại : </span>
                            </td>
                            <td>
                                <asp:TextBox ID="txtPassword" CssClass="txt_s" runat="server" TextMode="Password" MaxLength="15" ValidationGroup="ChangePWD"></asp:TextBox>
                                <asp:RequiredFieldValidator ID="rfvPassword" ControlToValidate="txtPassword" runat="server"
                                    ErrorMessage="*" ValidationGroup="ChangePWD"></asp:RequiredFieldValidator>
                                <asp:RegularExpressionValidator ID="revPasswordCurrent" ControlToValidate="txtPassword" ValidationGroup="ChangePWD"
                                    ValidationExpression="[a-zA-Z0-9@#$]+" runat="server" ErrorMessage="Mật khẩu chỉ gồm kí tự : a->z A->Z 1->9 @ # $"></asp:RegularExpressionValidator>
                            </td>
                        </tr>
                        <tr>
                            <td>
                                <span>Mật khẩu mới : </span>
                            </td>
                            <td>
                                <asp:TextBox ID="txtNewPassword" CssClass="txt_s" runat="server" TextMode="Password" MaxLength="15" ValidationGroup="ChangePWD"></asp:TextBox>
                                <asp:RequiredFieldValidator ID="rfvNewPassword" ControlToValidate="txtNewPassword" ValidationGroup="ChangePWD"
                                    runat="server" ErrorMessage="*"></asp:RequiredFieldValidator>
                                <asp:RegularExpressionValidator ID="RegularExpressionValidator1" ControlToValidate="txtNewPassword" ValidationGroup="ChangePWD"
                                    ValidationExpression="[a-zA-Z0-9@#$]+" runat="server" ErrorMessage="Mật khẩu chỉ gồm kí tự : a->z A->Z 1->9 @ # $"></asp:RegularExpressionValidator>
                            </td>
                        </tr>
                        <tr>
                            <td>
                                <span>Xác nhận mật khẩu mới : </span>
                            </td>
                            <td>
                                <asp:TextBox ID="txtNewPassword2" CssClass="txt_s" runat="server" TextMode="Password" MaxLength="15" ValidationGroup="ChangePWD"></asp:TextBox>
                                <asp:RequiredFieldValidator ID="rfvNewPassword2" ControlToValidate="txtNewPassword2" ValidationGroup="ChangePWD"
                                    runat="server" ErrorMessage="*"></asp:RequiredFieldValidator>
                                <asp:CompareValidator ID="cvNewPassword2" ControlToValidate="txtNewPassword2" ControlToCompare="txtNewPassword" ValidationGroup="ChangePWD"
                                    runat="server" ErrorMessage="Mật khẩu mới và mật khẩu mới xác nhận không khớp"></asp:CompareValidator>
                            </td>
                        </tr>
                        <tr>
                            <td>
                            </td>
                            <td>
                                <asp:Button ID="btnChangePWD" CssClass="search_btn blue" Width="150px" runat="server"
                                    Text="Thay đổi mật khẩu" OnClick="btnChangePWD_Click" ValidationGroup="ChangePWD" />
                            </td>
                        </tr>
                    </tbody>
                </table>
            </div>
        </div>
        <div class="clear">
        </div>
    </div>
</asp:Content>
